import React, { Component } from "react";
import { NavLink } from "react-router-dom";

export default class MyNavLink extends Component {
    render() {
        /**
         * 使用 this.props.children 获取标签内的内容
         */
        console.log(this.props);

        // const { children } = this.props;

        return (
            <NavLink
                activeClassName="nav-link-active"
                className="list-group-item"
                {...this.props}
            />
        );
    }
}
